/*
 * Copyright (c) Beicaizs.com Inc.
 * All Rights Reserved.
 */
package com.zlb.envmodify.example;

import com.zlb.envmodify.transform.DynamicEnvModify;

/**
 * @Description
 * @ClassName HotDeployeeExample
 * @Author zhuliangbing
 * @Date 2024/7/1 11:59
 * @Version 0.0.1
 */
public class HotTransformExample {

    /**
     * 请在配置vm option，路径按照实际情况设置
     * -Dlogging.level.root=INFO -javaagent:D:\code_zlb\zlb-java-envmodify\target\zlb-java-envmodify-2.8.9-release-jar-with-dependencies.jar
     *
     * @param args
     */
    public static void main(String[] args) throws InterruptedException {
        /**
         * 效果
         * 原来：原来的方法只返回hashCode
         * 插件：使用插件后，调用原来方法获取hashCode，并调整了格式
         */
        HotTransformExample hotDeployeeExample = new HotTransformExample();
        int i = 0;
        while (i++ < 20) {
            DynamicEnvModify.hotTransform(HotTransformExample.class);
            hotDeployeeExample.printSomething();
            Thread.sleep(3000);
        }
    }

    public void printSomething() {
    }

}
